
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>赏金提现</title>
<meta content="width=device-width,initial-scale=1,user-scalable=no" name="viewport">
<style>
*{margin:0;padding:0;}
body{font-size:14px;font-family:"微软雅黑";background:#f2f2f2;}
a{text-decoration:none;}
li{list-style:none;}
input{border:none;background:none;outline:none;}
.sjtx{position:relative;text-align:center;}
.sjtx_t{width: 84%;margin-left: 8%;    height: 70px; margin-top: 20px;}
.sjtx_t p{font-size:14px;line-height:65px; width:50%;float:left;}
.sjtx_t p img{}
.sjtx_t1{width:20%;float:left;}
.sjtx_j{width:100%;text-align:center;}
.sjtx_j p{line-height:30px;}
.sjtx_j1{width:90%;margin-left:5%;height:210px;background:#fff;border-radius:10px;margin-top:20px;}
.sjtx_j1 p{padding-top:10px;font-weight:bold;}
.tixian{width:90%;height:40px;line-height:40px;margin-top:10px;border-bottom:1px solid #eee;margin-left:5%;}
.tixian .text{width: 90%;height: 40px;line-height: 40px;}
.submit{width:90%;height:40px;line-height:40px;color:#fff;background:#1ed21b;text-align:center;font-size:15px;margin-top:70px;border-radius:10px;margin-left:5%;}
.submit a{display:block;width:100%;}
</style>
 <script src="__PUBLIC__/home/js/jquery-2.1.1.min.js"></script>
<script src="__PUBLIC__/layer/layer.js"></script>
</head>
<body>


<div class="sjtx_j">
<p>可提现赏金</p>
<p style="font-size:24px;">¥{$user.money}</p>
<p>提现手续费 {$sys.yongjin}%
</p>

<div class="sjtx_j1">

<div class="tixian"><label style="font-size:20px;">¥</label><input  type="text" id="money" name="money" value="" class="text"/></div>
<div class="tixian" ><label style="  font-size: 14px; display: block; width:30%; float: left;">提现密码：</label><input  type="password" value="" id="mima" class="text" style="width:68%;"/>
</div>

<!--<input type="button" class="submit" value="提现" onClick="tixian()"/>-->
<div  class="submit"><a onClick="tixian()">提现</a> </div>

</div>

</body>
</html>
<script>
  function tixian(){
    
	var money=$('#money').val();
	var mima=$('#mima').val();
	
	if(money<1){
	  alert('提现金额最低为1元');return;
	}
	
	if(mima==""){
	
	  alert('提现密码不能为空！');return;
	
	}
	
	
	layer.msg('正在处理提现,请勿刷新', {
	  icon: 16
	  ,shade: 0.01
	  ,time:2000000
	});
	
	$.post("{:U('User/savetixian')}",{"money":money,"mima":mima},function(re){
	  
	   layer.closeAll();
	  
	   if(re.msg==0){
	  
	    layer.alert(re.tishi,function(){
		
		  location.href="/index.php/User/tixian/keyword/{$Think.session.keyword}";
		
		});
	  
	   }
	   
	   if(re.msg==11){
	   
	      layer.alert('提现密码不正确');
	   
	   }
	   
	   
	   if(re.msg==2){
	   
	      layer.alert('提现失败,请联系客服',function(){
		
		  location.href="/index.php/User/tixian/keyword/{$Think.session.keyword}";
		
		   });
	     
	   
	   }
	   
	   
	   if(re.msg==5){
	   
	     layer.alert('提现金额不能小于2元');
	   
	   }
	   
	   if(re.msg==3){
	   
	     layer.alert('提现金额不能大于自身余额');
	   
	   }
	   
	   if(re.msg==4){
	   
	     layer.alert('只能最后一次扫码微信号提现');
	   
	   }
	   
	   
	   if(re.msg==88){
	   
	         layer.alert('您已成功提交提现申请,我们会尽快审核',function(){
		
		     location.href="/index.php/User/tixian/keyword/{$Think.session.keyword}";
		
		   });
	   
	   }
	
	
	})
	
	
    
}
function alltixian(){
  var totalmoney = "{$user.money}";
 $('#money').val(totalmoney);
}
</script>